{% extends 'ne.jinja2' %}
{% block query %}

SELECT

  gid AS __id__,

  {% filter geometry %}the_geom{% endfilter %} AS __geometry__,
  NULL::bytea AS __label__,

  {{ ne_common_properties() }},

  NULL::jsonb AS __boundaries_properties__,
  NULL::jsonb AS __earth_properties__,
  NULL::jsonb AS __landuse_properties__,
  NULL::jsonb AS __places_properties__,

  jsonb_build_object(
      'min_zoom', mz_road_min_zoom,
      'scalerank', scalerank,
      'featurecla', featurecla,
      'type', type,
      'expressway', expressway,
      'toll', toll,
      'sov_a3', sov_a3,
      'level', level,
      'continent', continent,
      'label', label,
      'name', name
  ) AS __roads_properties__,

  NULL::jsonb AS __water_properties__

FROM

  ne_10m_roads

WHERE

  {{ bounds['line']|bbox_filter('the_geom', 3857) }}
  AND mz_road_min_zoom < {{ zoom + 1 }}

{% endblock %}
